package online.keepon.wechatpush.scheduled;

import online.keepon.wechatpush.service.TemplateMsgService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

/**
 * @author top
 */
@Component
public class WechatPushScheduled {

    @Autowired
    private TemplateMsgService templateMsgService;

    @Scheduled(cron = "${wechat.cron}")
    public void wechatPush() {
        templateMsgService.push();
    }
}
